<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%--
  Created by IntelliJ IDEA.
  User: 周澳平
  Date: 2021/10/25
  Time: 21:01
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<!DOCTYPE html>
<html>
<head>
    <meta charset="UTF-8">
    <title>业绩查询</title>
    <link type="text/css" rel="stylesheet" href="fontsawesome/css/font-awesome.css"/>
    <link type="text/css" rel="stylesheet" href="css/datepicker.css"/>
    <link type="text/css" rel="stylesheet" href="css/style.css"/>
</head>
<body>
<div class="main_box">
    <h2><span></span>业绩查询</h2>
    <form action="${pageContext.request.contextPath}/findAllCard" method="post">
        <div class="search_box clearfix">
            <label class="f_left">开始日期：</label>
            <div class="date_box">
                <input type="text" name="cTime" id="start_date" readonly/>
                <i class="fa fa-calendar"></i>
            </div>
            <label class="f_left">结束日期：</label>
            <div class="date_box">
                <input type="text" name="endTime" id="end_date" readonly/>
                <i class="fa fa-calendar"></i>
            </div>
            <input type="submit" value="搜索" class="btn blue_btn"/>
        </div>
    </form>
    <div class="cont_box" style="border-top:1px dashed #ddd;">
        <p class="business_tit">营业额详情表</p>
        <table border="0" cellspacing="0" cellpadding="0" class="table business_table">
            <tbody>
            <tr>
                <td>充值收入</td>
                <td>${allCount}</td>
            </tr>
            <tr>
                <td>非会员收入</td>
                <td>${countOrders}</td>
            </tr>
            <tr>
                <td>大礼包收入</td>
                <td>${countGift}</td>
            </tr>
            <tr>
                <td>营业总额</td>
                <td>${allCount+countOrders+countGift}</td>
            </tr>
            </tbody>
        </table>
        <p class="business_tit">营业额说明</p>
        <ul class="business_info">
            <li>营业总额 = 充值收入 + 非会员收入 + 大礼包收入</li>
            <li>充值收入（<span>${allCount}</span>） =
                <c:forEach items="${count}" var="counts">
                    ${counts.clamp}收入（<span>${counts.count}</span>）
                    <c:if test="${counts.clamp=='储值卡'}">
                        +
                    </c:if>
                </c:forEach>
            </li>
            <li>储值卡消费总额：<span>${ordersSum}</span> 元</li>
            <li>年卡消费总次数：<span>${ordersCount}</span> 次</li>
            <li>年卡开卡总数：<span>${count1}</span> 张</li>
        </ul>
        <p class="business_tit">非会员收入详情表</p>
        <table border="0" cellspacing="0" cellpadding="0" class="table">
            <thead>

            <tr>
                <th class="slash">
                    <div class="slash_line">
                    </div>
                </th>
                <c:forEach items="${orders}" var="orders">
                    <th>${orders.mode}</th>
                </c:forEach>
                <th>总计</th>
            </tr>
            </thead>
            <tbody>
            <tr>
                <td>消费金额</td>
                <c:forEach items="${orders}" var="orders">
                    <td>${orders.money}</td>
                </c:forEach>
                <td>${countOrders}</td>
            </tr>
            <tr>
                <td>消费次数</td>
                <c:forEach items="${orders}" var="orders">
                    <td>${orders.count}</td>
                </c:forEach>
                <td>${countOrder}</td>
            </tr>

            </tbody>
        </table>
        <p class="business_tit">储值卡详情表</p>
        <table border="0" cellspacing="0" cellpadding="0" class="table business_table">
            <tbody>
            <c:forEach items="${list}" var="lists">
                <tr>
                    <td>${lists.clamps}</td>
                    <td>${lists.count}</td>
                </tr>
            </c:forEach>
            <tr>
                <td>总计</td>
                <td>${countCard}</td>
            </tr>
            </tbody>
        </table>
    </div>
</div>
<!--javascript include-->
<script src="js/jquery-2.2.1.min.js"></script>
<script src="js/jquery.dataTables.min.js"></script>
<script src="js/bootstrap-datepicker.js"></script>
<script src="js/jquery.validate.min.js"></script>
<script src="js/other.js"></script>
<script>
    $(function () {
        var tdW = $(".slash").width(),
            tdH = $(".slash").height();
        $(".slash_line").css({"border-left-width": parseInt(tdW), "border-top-width": parseInt(tdH)});
    });
</script>
</body>
</html>

